﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.Configuration;
using System.Data.Common;
using Common;

namespace DataAccess
{
    public class ConnectionClass
    {
        public ElectrosEntities Entity { get; set; }
        public DbTransaction Transaction { get; set; }

        public ConnectionClass()
        {
            Entity = new ElectrosEntities();
        }

        /*public ConnectionClass(bool isAdmin)
        {
            string connectionString = "";
            if (isAdmin)
            {
                //Admin Connection String
                connectionString = WebConfigurationManager.ConnectionStrings["ElectrosEntities"].ConnectionString;
                    //WebConfigurationManager.ConnectionStrings["ElectrosEntities"].ConnectionString;
            }
            else
            {
                //Other Connection String
                connectionString = WebConfigurationManager.ConnectionStrings["ElectrosEntities"].ConnectionString;
            }

            Entity = new ElectrosEntities(connectionString);
        }*/
    }
}
